﻿using System;
using System.Web;

namespace Zadani09
{
    public partial class Chyba : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            HttpContext kontext = HttpContext.Current;
            Object obj;

              // zakladni info o hlasce
            if ((obj = kontext.Items["popis"]) != null)
                lbl_chyba.Text = (String)obj;

              // stack trace v pripade nastaveneho debugu
            if (Zadani09.util.Constants.DEBUG &&
                (obj = kontext.Items["stacktrace"]) != null)
            {
                lbl_chyba.Text += "<br/><br/>Stacktrace:<br/><pre>"
                                    + (String)obj + "</pre>";
            }
        }
    }
}
